I need to know about the difference of int,int16,int 32 and int64 other than its size?
335926-May-2012
Updated on 15-Sep-2020
Home / DeveloperSection / Interviews / I need to know about the difference of int,int16,int 32 and int64 other than its size?
John Smith
26-May-2012The only real difference here is the size. All of the int types here are signed integer values which have varying sizes
Int16
: 2 bytesInt32
andint
: 4 bytesInt64
: 8 bytesThere is one small difference between
Int64
and the rest. On a 32 bit platform assignments to anInt64
storage location are not guaranteed to be atomic. It is guaranteed for all of the other types.